<!DOCTYPE html>
<html lang="en">
	<head>
		<title>Recaf - modern bytecode editor</title>
		<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
		<meta name="viewport" content="width=device-width">
		<meta name="description" content="Recaf is a modern java bytecode editor using Objectweb's ASM and JavaFX.">
		<meta name="keywords" content="java,bytecode,editor,recaf,reverse engineering">
		<link rel="icon" type="image/x-icon" href="favicon.ico"/>
		<link href="https://fonts.googleapis.com/css?family=Roboto:300" rel="stylesheet">
		<link rel="stylesheet" href="css/style.css">
		<link rel="stylesheet" href="css/table.css">
		<link rel="stylesheet" href="css/code.css">
	</head>
	<body>
		<header>
			<div class="beam container-wide">
				<div class="box-left">
					<a href="index.html"><div class="logo"></div></a>
				</div>
				<div class="box-right">
					<nav>
						<a href="index.html">Home</a>
						<a href="documentation.html">Documentation</a>
						<a href="features.html">Features</a>
						<a href="https://github.com/Col-E/Recaf">Github</a>
					</nav>
				</div>
			</div>
		</header>
		<section id="content">
			<h2 id="disp">Display</h2>
			<p><b>Display</b> options change how the user-interfaces look and behave.</p>
			<table>
				<thead>
					<tr>
						<th>Name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Simplify type descriptors</td>
					<td>Hides package name for type descriptors.<br>
					<span class="code">com/example/Clazz</span> becomes <span class="code">Clazz</span></td>
				</tr>
				<tr>
					<td>Inline jump help</td>
					<td>Shows opcode-specific jump logic next to displayed opcodes.<br>
					<span class="code">IFNE (LABEL X)</span> becomes <span class="code">IFNE [$0 != 0 -&gt; offset] (LABEL X)</span></td>
				</tr>
				<tr>
					<td>Show search's method types</td>
					<td>Search results of method types will show arguments and return type in addition to the method name. Useful for obfuscated programs.</td>
				</tr>
				<tr>
					<td>Top-most editor windows</td>
					<td>When editing a value, keep the editor window top-most. This prevents windows being forgotten about behind the primary window.</td>
				</tr>
				<tr>
					<td>Language</td>
					<td>
						Value determines which language JSON to read translations from. Please contribute if you can: <a href="https://github.com/Col-E/Recaf/issues/34">here</a>
					</td>
				</tr>
				<tr>
					<td>Style</td>
					<td>
						Custom stylesheet to use when displaying JavaFX components. See the <a href="theme.html">style guide</a> for more information.
					</td>
				</tr>
				<tr>
					<td>Log level</td>
					<td>Level of verbosity of messages shown in the console</td>
				</tr>
				<tr>
					<td>Show button-bar</td>
					<td>Show the ease-of-access button-bar in the UI. Restarting is required for the change to be effective.</td>
				</tr>
				<tr>
					<td>Max tree name length</td>
					<td>Allows setting a maximum length for names in the file tree. Useful for heavily obfuscated classes with long names.</td>
				</tr>
				<tr>
					<td>Show SourceFile names</td>
					<td>Adds the SourceFile value next to classes names in the file  tree.</td>
				</tr>
			</table>
			<h2 id="asm">ASM</h2>
			<p><b>ASM</b> options change how the bytecode parser is configured. The values of these options only affect classes that are modified. Classes that are not modified are not regenerated when exported. The exact original bytecode is used if a class has not been modified.</p>
			<table>
				<thead>
					<tr>
						<th>Name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Version</td>
					<td>ASM library version to use. This really should only be set to lower values if you are attaching to a process with an older version of ASM already loaded into the JVM.</td>
				</tr>
				<tr>
					<td>Compute maxs</td>
					<td>Allow ASM to compute max-stack/local-variable-table sizes on export.</td>
				</tr>
				<tr>
					<td>Compute frames</td>
					<td>Allow ASM to compute stack frames on export. This should always remain on for output to executable without the JVM argument <span class="code">-noverify</span>.</td>
				</tr>
				<tr>
					<td>Reflection export</td>
					<td>Allow ASM to use reflection to create more accurate stack-frames from core JRE classes.</td>
				</tr>
				<tr>
					<td>Skip code</td>
					<td>Allow ASM to skip parsing method opcodes.</td>
				</tr>
				<tr>
					<td>Skip debug</td>
					<td>Allow ASM to skip debug information such as variable names and source files.</td>
				</tr>
				<tr>
					<td>Skip frames</td>
					<td>Allow ASM to skip existing stack-frames when parsing new input.</td>
				</tr>
				<tr>
					<td>Expand frames</td>
					<td>Allow ASM to expand existing stack-frames into a common format.</td>
				</tr>
				<tr>
					<td>Linked method renaming</td>
					<td>When renaming methods, rename all child and parent declarations too.</td>
				</tr>
				<tr>
					<td>Lock linked library names</td>
					<td>Disallow renaming of known library methods. Requires <u>linked method renaming</u> to be active. For example if you create a class that extends <span class="code">java/io/Closeable</span> your class's <span class="code">close()</span> will be locked since it extends a library class's method.</td>
				</tr>
				<tr>
					<td>Verify</td>
					<td>When edits create invalid bytecode, highlight the editor window. <a href="screenshots/uie-method-instructions-verify.png">Also prevent exporting</a> until verification passes all modified classes.</td>
				</tr>
			</table>
			<h2 id="keybinds">Keybinds</h2>
			<p><b>Keybinds</b> are <span class="code">Control + {KEY}</span> where the key is a user-defined letter.</p>
			<table>
				<thead>
					<tr>
						<th>Name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Use keybinds</td>
					<td>Allows keybinds to be intercepted on the main window.</td>
				</tr>
				<tr>
					<td>Create save-state</td>
					<td>Keybind for saving recent changes to the history manager.</td>
				</tr>
				<tr>
					<td>Export</td>
					<td>Keybind for exporting modified files.</td>
				</tr>
				<tr>
					<td>Open file</td>
					<td>Keybind for opening a new file to edit.</td>
				</tr>
				<tr>
					<td>Search</td>
					<td>Keybind for opening a new search window.</td>
				</tr>
				<tr>
					<td>Copy</td>
					<td>Keybind for copying custom data. Current support includes:
						<ul>
							<li>Method opcodes</li>
						</ul>
						<span class="faint">Standard system copy/paste still works</span>
					</td>
				</tr>
				<tr>
					<td>Paste</td>
					<td>Keybind for pasting custom data. Current support includes:
						<ul>
							<li>Method opcodes</li>
						</ul>
						<span class="faint">Standard system copy/paste still works</span>
					</td>
				</tr>
				<tr>
					<td>Find</td>
					<td>Keybind for opening find dialogs, applies to the following windows:
						<ul>
							<li>Decompiler</li>
							<li>Instructions</li>
						</ul>
					</td>
				</tr>
			</table>
			<h2 id="updates">Updates</h2>
			<p><b>Updates</b> options change the start-up auto-updater behavior.</p>
			<table>
				<thead>
					<tr>
						<th>Name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Allow update checking</td>
					<td>If enabled updates will be checked for according to the frequency value, then downloaded and run.<br>Disabling will block all update checks.</td>
				</tr>
				<tr>
					<td>Last check</td>
					<td>Last time since checking for updates.</td>
				</tr>
				<tr>
					<td>Frequency</td>
					<td>Minimum time between checks.
					<table>
						<thead>
							<tr>
								<th>Name</th>
								<th>Description</th>
							</tr>
						</thead>
						<tr>
							<td>Always</td>
							<td>Check for updates every launch.</td>
						</tr>
						<tr>
							<td>Daily</td>
							<td>Check for updates after 24 hours since the value stored in <span class="code">Last check</span>.</td>
						</tr>
						<tr>
							<td>Weekly</td>
							<td>Check for updates after 7 days since the value stored in <span class="code">Last check</span>.</td>
						</tr>
					</table>
					</td>
				</tr>
			</table>
			<h2 id="other">Other</h2>
			<p><b>Other</b> options are miscellaneous options that do not really belong in any one place.</p>
			<table>
				<thead>
					<tr>
						<th>Name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Maximum threads</td>
					<td>The maximum number of threads to allow for multithreaded tasks.</td>
				</tr>
				<tr>
					<td>Maximum recent files</td>
					<td>The maximum number of files to show in the "File > Recent" menu.</td>
				</tr>
			</table>
			<h2 id="cfr">CFR</h2>
			<p><b>CFR</b> options affect how decompiled code is created and formatted. The official CFR decompiler page is: <a href="http://www.benf.org/other/cfr/">benf.org/other/cfr/</a></p>
			<table id="table">
				<thead>
					<tr>
						<th>Parameter name</th>
						<th>Description</th>
					</tr>
				</thead>
				<tr>
					<td>Aggressive exception optimization</td>
					<td>Remove nested exception handlers if they don't change semantics</td>
				</tr>
				<tr>
					<td>Aggressive threshold</td>
					<td>Opcode count at which to trigger aggressive reductions</td>
				</tr>
				<tr>
					<td>Allow correcting</td>
					<td>Allow transformations which correct errors, potentially at the cost of altering emitted code behavior.</td>
				</tr>
				<tr>
					<td>Array iteration</td>
					<td>Re-sugar array based iteration.</td>
				</tr>
				<tr>
					<td>Collection iteration</td>
					<td>Re-sugar collection based iteration.</td>
				</tr>
				<tr>
					<td>Comment monitors</td>
					<td>Replace monitors with comments - useful if we're completely confused.</td>
				</tr>
				<tr>
					<td>Comment info</td>
					<td>Output comments describing decompiler status, fallback flags etc.</td>
				</tr>
				<tr>
					<td>Decode enum-switch</td>
					<td>Re-sugar switch on enum</td>
				</tr>
				<tr>
					<td>Decode finally</td>
					<td>Re-sugar finally statements</td>
				</tr>
				<tr>
					<td>Decode lambdas</td>
					<td>Re-build lambda functions</td>
				</tr>
				<tr>
					<td>Decode string-switch</td>
					<td>Re-sugar switch on String</td>
				</tr>
				<tr>
					<td>Dump class path</td>
					<td>Dump class path for debugging purposes</td>
				</tr>
				<tr>
					<td>Eclipse</td>
					<td>Enable transformations to handle eclipse code better.</td>
				</tr>
				<tr>
					<td>Clean Scala</td>
					<td>Hide things which aren't helpful in scala output (serialVersionUID, @ScalaSignature).</td>
				</tr>
				<tr>
					<td>Use try-with-resource</td>
					<td>When active attempt to display try-catch blocks as try-with-resource blocks.</td>
				</tr>
				<tr>
					<td>Force condition propagation</td>
					<td>Pull results of deterministic jumps back through some constant assignments.</td>
				</tr>
				<tr>
					<td>Force exception pruning</td>
					<td>Try to extend and merge exceptions more aggressively.</td>
				</tr>
				<tr>
					<td>Force returning ifs</td>
					<td>Move return up to jump site.</td>
				</tr>
				<tr>
					<td>Force top-sort</td>
					<td>Force basic block sorting. Useful for flow-obfuscated code.</td>
				</tr>
				<tr>
					<td>Force top-sort:aggressive</td>
					<td>Force extra aggressive topsort options.</td>
				</tr>
				<tr>
					<td>For-loop capturing</td>
					<td>Allow for loops to aggressively roll mutations into update section, even if they don't appear to be involved with the predicate</td>
				</tr>
				<tr>
					<td>Hide bridge methods</td>
					<td>Hide methods with bridge access</td>
				</tr>
				<tr>
					<td>Hide lang imports</td>
					<td>Hide imports from java.lang.*</td>
				</tr>
				<tr>
					<td>Hide long strings</td>
					<td>Hide very long strings - useful if obfuscators have placed fake code in strings</td>
				</tr>
				<tr>
					<td>Hide UTF8</td>
					<td>Hide UTF8 characters - quote them instead of showing the raw characters</td>
				</tr>
				<tr>
					<td>Decompile inner classes</td>
					<td>Include inner classes in decompilation of outer-class.</td>
				</tr>
				<tr>
					<td>Java 4 class object</td>
					<td>Reverse java 1.4 class object construction</td>
				</tr>
				<tr>
					<td>Labelled blocks</td>
					<td>Allow code to be emitted which uses labelled blocks, (handling odd forward gotos).</td>
				</tr>
				<tr>
					<td>Lenient</td>
					<td>Be a bit more lenient in situations where we'd normally throw an exception</td>
				</tr>
				<tr>
					<td>Lift constructor init</td>
					<td>Lift initialization code common to all constructors into member initialization</td>
				</tr>
				<tr>
					<td>Emit @Override</td>
					<td>Generate @Override annotations (if method is seen to implement interface method, or override a base class method)</td>
				</tr>
				<tr>
					<td>Pull code case</td>
					<td>Pull code into case statements aggressively.</td>
				</tr>
				<tr>
					<td>Recover</td>
					<td>Allow more and more aggressive options to be set if decompilation fails</td>
				</tr>
				<tr>
					<td>Recover type clash</td>
					<td>Split lifetimes where analysis caused type clash</td>
				</tr>
				<tr>
					<td>Recover type hints</td>
					<td>Recover type hints for iterators from first pass.</td>
				</tr>
				<tr>
					<td>Recpass</td>
					<td>Decompile specifically with recovery options from pass #X. (really only useful for debugging)</td>
				</tr>
				<tr>
					<td>Relink const-strings</td>
					<td>Relink constant strings - if there is a local reference to a string which matches a static final, use the static final.</td>
				</tr>
				<tr>
					<td>Hide bad generics</td>
					<td>Hide generics where we've obviously got it wrong, and fallback to non-generic</td>
				</tr>
				<tr>
					<td>Remove boilerplate</td>
					<td>Remove boilderplate functions - constructor boilerplate, lambda deserialisation etc</td>
				</tr>
				<tr>
					<td>Remove unused methods</td>
					<td>Remove pointless methods - default constructor etc</td>
				</tr>
				<tr>
					<td>Remove inner class synthetics</td>
					<td>Remove (where possible) implicit outer class references in inner classes</td>
				</tr>
				<tr>
					<td>Rename duplicate members</td>
					<td>Rename ambiguous/duplicate members.</td>
				</tr>
				<tr>
					<td>Rename enum identifiers</td>
					<td>Rename ENUM identifiers which do not match their 'expected' string names.</td>
				</tr>
				<tr>
					<td>Rename illegal identifiers</td>
					<td>Rename identifiers which are not valid java identifiers.</td>
				</tr>
				<tr>
					<td>Rename small members</td>
					<td>Rename small members. Useful for proguard-like obfuscation.</td>
				</tr>
				<tr>
					<td>Show inferrable</td>
					<td>Decorate methods with explicit types if not implied by arguments.</td>
				</tr>
				<tr>
					<td>Show OPs</td>
					<td>Show some (cryptic!) debug info.</td>
				</tr>
				<tr>
					<td>Show version</td>
					<td>Show CFR version used in header</td>
				</tr>
				<tr>
					<td>Silent</td>
					<td>Don't display state while decompiling</td>
				</tr>
				<tr>
					<td>Static init return</td>
					<td>Try to remove return from static init</td>
				</tr>
				<tr>
					<td>Clean StringBuffer</td>
					<td>Convert new Stringbuffer().add.add.add to string + string + string</td>
				</tr>
				<tr>
					<td>Clean StringBuilder</td>
					<td>Convert new Stringbuilder().add.add.add to string + string + string</td>
				</tr>
				<tr>
					<td>Deinfigy string concat</td>
					<td>Convert usages of StringConcatFactor to string + string + string</td>
				</tr>
				<tr>
					<td>Sugar asserts</td>
					<td>Re-sugar assert calls</td>
				</tr>
				<tr>
					<td>Sugar boxing</td>
					<td>Where possible, remove pointless boxing wrappers</td>
				</tr>
				<tr>
					<td>Sugar enums</td>
					<td>Re-sugar enums</td>
				</tr>
				<tr>
					<td>Switch expressions</td>
					<td>Decompile Java 13 switch expressions. Disable to translate to pre-Java 13 switch statements.</td>
				</tr>
				<tr>
					<td>Tidy monitors</td>
					<td>Remove support code for monitors - eg catch blocks just to exit a monitor</td>
				</tr>
				<tr>
					<td>Use name table</td>
					<td>Use local variable name table if present.</td>
				</tr>
			</table>
		</section>
	</body>
</html>